/* eslint-disable @typescript-eslint/explicit-function-return-type */
/* eslint-disable @typescript-eslint/explicit-module-boundary-types */
import { App } from 'vue';
import { registerFormDetailProvider } from '@ibiz-template/runtime';
import { GroupShiftsMdctrl } from './group-shifts-mdctrl';
import { GroupShiftsMdctrlProvider } from './group-shifts-mdctrl.provider';

export default {
  install(app: App) {
    // 全局注册表单成员插件组件
    app.component(GroupShiftsMdctrl.name!, GroupShiftsMdctrl);
    // 全局注册表单成员插件适配器，FORM_USERCONTROL是插件类型，ATTENDANCE_GROUP_SHIFTS_MDCTRL是插件标识
    registerFormDetailProvider(
      'FORM_USERCONTROL_ATTENDANCE_GROUP_SHIFTS_MDCTRL',
      () => new GroupShiftsMdctrlProvider(),
    );
  },
};
